<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title>便民服务-企业详细信息</title>
		<meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1,user-scalable=no,viewport-fit=cover">
		<meta name="apple-mobile-web-app-capable" content="yes">
		<meta name="apple-mobile-web-app-status-bar-style" content="black">
		<link rel="stylesheet" href="../../css/mui.min.css">
		<link rel="stylesheet" href="../../css/app.css">		
	</head>
	<style type="text/css">
		body{overflow-y:auto ;}
	   .mui-content{position: absolute;top: 0;left: 0;height:100%;  background:#f4f4f4 url(../../images/service/company_banner01.png)  no-repeat; background-size:100% 200px;}
	   .mui-content .mui-title{color: #fff;}
	   .mui-bar{background: none;}
	   .mui-content .idCard{margin:0px auto;}
	   .mui-content .idCard>h3{color: #666; height: .8rem; line-height: .8rem; background-color: #f5f5f5; font-size: .32rem; padding-left: .3rem; box-sizing: border-box;}
	   .idCard .ico_card{display: inline-block; vertical-align: middle; margin:-.05rem .1rem 0 0; width: .5rem; height: .48rem; background: url(../../images/service/s_ico01.png) no-repeat; background-size:cover;}
	   .mui-input-group:before,.mui-input-group:after{background: none;}
	   .mui-input-group{margin: .5rem 0px 0px .2rem;}
	   .mui-input-group .mui-input-row{height: .88rem; line-height: .88rem;}
	   .mui-input-row label{font-size: .3rem; color: #999999; padding: .33rem; box-sizing: border-box;}
	   .mui-input-group .mui-input-row:after{background-color:#e5e5e5; left: 5px;}
	   .mui-input-row label~input{font-size: .3rem; color: #999999;height: .88rem; line-height: .88rem;}
	   .mui-input-row .input-code{width: 40%; float: left;}
	   .mui-input-row .phone_code>img{display: block; width: 1.33rem; height: .63rem; float: right; margin: .1rem 0px 0px 0px;}
	   button[type=button]{margin: .6rem .25rem; color: #fff; width: 6.7rem; padding: .25rem 0px; background-color: #ff7800; font-size: .32rem; border: none;}
	   .mui-input-group .ico_code{background: url(../../images/service/s_ico02.png) no-repeat; display: inline-block; vertical-align: middle; width: .34rem; height: .38rem; background-size: cover; margin: 0px .1rem 0px 0px;}
	   .company-content{width: 6.7rem;margin: .9rem auto 0 auto;}
	   input[type=search]{background-color: #fff;font-size: .28rem;}
	   .mui-search .mui-placeholder{font-size: .28rem;}
	   .mui-search .mui-placeholder .mui-icon{color:#666;}
	   .result_content{margin-top: .3rem;}
	   .result_content>h3{color: #fff; font-size: .3rem;font-weight:normal;}
	   .result_content .ico_result{display: inline-block; vertical-align: middle; width: .4rem; height: .44rem; background: url(../../images/service/list_icon.png) no-repeat center top; background-size: cover; margin: -.1rem .1rem 0px 0px;}
	   .float_right{float: right; color: #333; font-size: .3rem;}
	   .result_list{margin: .25rem auto;}
	   .mui-slider{width: 6.7rem!important;margin: .6rem auto 1.5rem auto;border-radius: 5px; margin-top: .3rem; width: 100%; height: auto; ;}
       .mui-table-view{border-radius: 5px; padding: .1rem;}
	   .mui-table-view-cell{color: #999; font-size: .3rem; padding: .2rem}
	   .mui-table-view .title{color: #0096ff; font-size: .3rem;}
	   .borderNone:after,.mui-table-view:after,.borderNone:before{background:none;}
	   .title:after{background:#c8c7cc;}
	   .mui-bar-transparent{background:rgba(22,83,252,0);}
       .mui-bar-nav~.mui-content .mui-slider.mui-fullscreen{top:2rem;}
	   .mui-table-view-cell.mui-active{background-color: #fff;}
	   .result_content>.black{color:#333;margin-top:.35rem;}
	   .result_content>.black .ico_result{background:url(../../images/service/list_gray.png) no-repeat center top;background-size:100% 100%;}
	   .mui-table-view:before{content: none;}
	</style>
	<body>
		<!-- 主体start -->
		<div class="mui-content">		
			<!-- 企业信息查询start -->
			<div class="company-content">
				<div class="result_content" id="compInfo">
					<h3><i class="ico_result"></i>基本信息</h3>						
					<div class="result_list">					
						<ul class="mui-table-view">
							<li class="mui-table-view-cell borderNone title">{{comp.name}} </li>							
						    <li class="mui-table-view-cell borderNone">法人代表：
						       <span class="float_right">{{comp.legalPersonName}}</span>
						    </li>
						    <li class="mui-table-view-cell borderNone">注册资本：
						       <span class="float_right">{{comp.regCapital}}</span>
						    </li>
						    <li class="mui-table-view-cell borderNone">注册时间：
						       <span class="float_right">{{comp.estiblishTime}}</span>
						    </li>
						    <li class="mui-table-view-cell">经营状态：
						       <span class="float_right">{{comp.regStatus}}</span>
						    </li>
						</ul>						
					</div>	
					<h3 class="black"><i class="ico_result"></i>详细信息</h3>						
					<div class="result_list">					
						<ul class="mui-table-view borderNone">
						    <li class="mui-table-view-cell borderNone">工商注册号:
						       <span class="float_right">{{comp.regNumber}}</span>
						    </li>
						    <li class="mui-table-view-cell borderNone">行业：
						       <span class="float_right">{{comp.industry}}</span>
						    </li>
						    <li class="mui-table-view-cell borderNone">注册机构：
						       <span class="float_right">{{comp.regInstitute}}</span>
						    </li>	
						    <li class="mui-table-view-cell borderNone">组织机构代码：
						       <span class="float_right">{{comp.orgNumber}}</span>
						    </li>
						    <li class="mui-table-view-cell borderNone">营业期限：
						       <span class="float_right">{{comp.toTime}}</span>
						    </li>
						    <li class="mui-table-view-cell borderNone">统一信用代码：
						       <span class="float_right">{{comp.creditCode}}</span>
						    </li>
						    <li class="mui-table-view-cell borderNone">核准日期：
						       <span class="float_right">{{comp.approvedTime}}</span>
						    </li>						    
						</ul>						
					</div>	
				</div>	
			<!-- 企业信息查询证end -->
		</div>
		<!-- 主体end -->	
	</body>
	<script src="../../js/mui.min.js"></script><!-- mui -->
	<script src="../../js/common.js"></script><!-- 共用rem适配-js -->
	<script src="../../js/jquery2.2.4.min.js"></script>	<!-- jquery -->
	<script src="../../js/mui.pullToRefresh.js"></script>
	<script src="../../js/mui.pullToRefresh.material.js"></script>
	<script src="../../js/vue.min.js"></script>	
	<script type="text/javascript">
			mui.init();
			(function($) {
				//阻尼系数
				var deceleration = mui.os.ios?0.003:0.0009;
				$('.mui-scroll-wrapper').scroll({
					bounce: false,
					indicators: true, //是否显示滚动条
					deceleration:deceleration
				});
				$.ready(function() {
					//循环初始化所有下拉刷新，上拉加载。
					$.each(document.querySelectorAll('.mui-slider-group .mui-scroll'), function(index, pullRefreshEl) {
						$(pullRefreshEl).pullToRefresh({
//							down: {
//								callback: function() {
//									var self = this;
//									setTimeout(function() {
//										var ul = self.element.querySelector('.mui-table-view');
//										ul.insertBefore(createFragment(ul, index, 10, true), ul.firstChild);
//										self.endPullDownToRefresh();
//									}, 1000);
//								}
//							},
							up: {
								callback: function() {
									var self = this;
									setTimeout(function() {
										var ul = self.element.querySelector('.mui-table-view');
										ul.appendChild(createFragment(ul, index, 5));
										self.endPullUpToRefresh();
									}, 1000);
								}
							}
						});
					});
					var createFragment = function(ul, index, count, reverse) {
						var length = ul.querySelectorAll('li').length;
						var fragment = document.createDocumentFragment();
						var li;
						for (var i = 0; i < count; i++) {
							li = document.createElement('li');
							li.className = 'mui-table-view-cell';
							li.innerHTML = '第' + (index + 1) + '个搜索结果列表-' + (length + (reverse ? (count - i) : (i + 1)));
							fragment.appendChild(li);
						}
						return fragment;
					};
				});
			})(mui);
			var mv = new Vue({
				el:'#compInfo',
				data:{
					comp:''
				}
			});
			mui.plusReady(function(){
				var companyId = utils.getUrlParam('companyId');
				utils.ajax('appHttpService/getCompanyDetailInfo.do',function(data){
					var data = JSON.parse(data);
					if (data.code == '0') {//成功
						var result = JSON.parse(data.result);
						mv.comp = result.result;
						closeWaitingAndShowView();
					} else {
						mui.toast(data.result);
					}
				},'companyId='+companyId,null,function(){
					mui.toast('抱歉，当前服务不可用，请稍后再试');
				})
			})
	</script>
</html>
